package com.controller.recycleindent;

import com.alibaba.fastjson.JSONObject;
import com.utils.DataTables;
import com.service.ReclamationOrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import javax.servlet.http.HttpServletRequest;
/**
 *  废品订单 Controller
 */

@Controller
@RequestMapping("/RecycleIndentController")
public class RecycleIndentController {

    @Autowired
    private ReclamationOrderService reclamationOrderService;

    @Autowired
    HttpServletRequest request;// 请求

    /**
     * 显示废品订单分页数据
     *
     * @return
     */
    @RequestMapping(value = "/getPageList.do", produces = "application/json; charset=utf-8")
    @ResponseBody
    public String getPageList() {
        return JSONObject.toJSONString(reclamationOrderService.getPageList(DataTables.getInstance(request, null)));
    }
}
